﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Smartee.RichText
{
    public class Body
    {
        protected List<Container> _containers = new List<Container>();

        public void Add(Container newItem) { _containers.Add(newItem); }
        public bool IsEmpty { get { return _containers.Count == 0; } }

        public virtual void Accept(IVisitor visitor)
        {
            foreach (Container container in _containers)
                container.Accept(visitor);
        }
    }
}
